Repository navigation
ELFCore: Parse core notes without pyelftools - #889
Merged
Merged
Conversation
pyelftools 5466000 ("Notes fixes", unreleased) names note types only for
the owners whose namespace it knows, so FreeBSD notes now arrive with
numeric types and the "NT_PRSTATUS" comparison never matches; every
FreeBSD core loaded without threads. It also decodes each descriptor from
its own bytes alone, and its x32 NT_PRPSINFO struct, with 32-bit uid and
gid, is four bytes longer than the note, so loading an x32 core raised
ELFParseError.
Iterate PT_NOTE segments in ELFCore, keep note types as numbers, and parse
NT_PRPSINFO and NT_FILE from the raw descriptor. pr_fname is read from the
end of NT_PRPSINFO, which is where it sits on every ABI, which also fixes
x32 cores reporting pr_fname "t" under every released pyelftools.
Member
Author
|
Related (but not deprecating this PR): eliben/pyelftools#700 |
Member
|
Corpus decompilation diffs can be found at angr/dec-snapshots@master...angr/cle_889 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A recent commit in pyelftools (eliben/pyelftools@5466000) causes cle to fail to load notes in FreeBSD core files. We are now parsing core notes without pyelftools.